﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Provider/PersonalAccident/PersonalAccident.master" AutoEventWireup="true" CodeFile="ViewBenefitScale.aspx.cs" Inherits="Provider_PersonalAccident_ViewBenefitScale" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<div class="provider_inner">
        <h1>
            Personal Accident Insurance
        </h1>
        <div class="right_action">
            <asp:HyperLink runat="server" ID="lnkNewClaimInfo" NavigateUrl="~/Provider/PersonalAccident/AddNewBenefitScale.aspx"
                Text="New"></asp:HyperLink>
        </div>
        <fieldset>
            <dl>
                <dt>
                    <label>
                        Plan Name</label></dt>
                <dd>
                    <asp:DropDownList ID="ddlPlanName" runat="server" class="text" Width="255px" 
                        AutoPostBack="true" onselectedindexchanged="ddlPlanName_SelectedIndexChanged"></asp:DropDownList>
                   <asp:TextBox ID="txtProviderComId" runat="server" Text="0" Visible="false"></asp:TextBox>
                </dd>
            </dl>
        </fieldset>
        <asp:GridView ID="grvPABenefitscale" runat="server" AllowPaging="True" AutoGenerateColumns="false"
            CellPadding="2" DataKeyNames="PAInsId" EmptyDataText="There are no data records to display."
            DataSourceID="sqlDsPABenefitscale"  CssClass="progridstyle" 
            GridLines="None" onrowdatabound="grvPABenefitscale_RowDataBound" >
            <Columns>
                <asp:BoundField DataField="PAInsId" HeaderText="PAInsId" InsertVisible="False" ReadOnly="True"
                    SortExpression="PAInsId" Visible="False" />
                <asp:BoundField DataField="PlanName" HeaderText="Plan Name" SortExpression="PlanName" />
                <asp:BoundField DataField="BenefitName" HeaderText="Bene fitName" SortExpression="BenefitName" />
                <asp:BoundField DataField="PolicyType" HeaderText="Policy Type" SortExpression="PolicyType" />
                <asp:BoundField DataField="DeathPerDisable" HeaderText="Death / Permanent Disable (%)" SortExpression="DeathPerDisable" />
                <asp:CheckBoxField DataField="Status" HeaderText="Status" SortExpression="Status" />            
                <asp:HyperLinkField HeaderText="Select" Text="Select" Target="_self" DataNavigateUrlFormatString="AddNewBenefitScale.aspx?PABenefitId={0}"
                    DataNavigateUrlFields="PAInsId"></asp:HyperLinkField>
            </Columns>
            <FooterStyle />
            <PagerStyle />
            <SelectedRowStyle CssClass="progridover" />
            <HeaderStyle CssClass="progridheader" />
            <EditRowStyle />
            <AlternatingRowStyle CssClass="progridodd" />
            <RowStyle CssClass="progrideven" />
        </asp:GridView>
        <asp:SqlDataSource ID="sqlDsPABenefitscale" runat="server" ConnectionString="<%$ ConnectionStrings:CE_DBConnectionString %>"
            SelectCommand="sprocPABenefitScaleSelectItemList" SelectCommandType="StoredProcedure">
            <SelectParameters>
                <asp:ControlParameter ControlID="txtProviderComId" Name="PACompanyId" PropertyName="Text"
                    Type="Int64" />
                <asp:ControlParameter ControlID="ddlPlanName" Name="PlanName" PropertyName="SelectedValue"
                    Type="String" />
            </SelectParameters>
        </asp:SqlDataSource>
        <asp:ImageButton OnClientClick="javascript:return confirm('Are you sure to go back?');"
            ID="ibtBack" runat="server" ImageUrl="~/Provider/images/buttons/back1.gif" 
            onclick="ibtBack_Click" />
    </div>
</asp:Content>

